xenstore-ls -f for find(1)-like output
authorKeir Fraser <keir.fraser@citrix.com>
Wed, 5 Dec 2007 11:07:12 +0000 (11:07 +0000)
committerKeir Fraser <keir.fraser@citrix.com>
Wed, 5 Dec 2007 11:07:12 +0000 (11:07 +0000)
commit1bb3512f969b20f229cdc092e94afab888dac317
tree1423a8f92333a8da1e3d935fb439368bdf5e4d10
parentdd36792405db37a70f76b7df23e2463499f21d9a
xenstore-ls -f for find(1)-like output

The current output of xenstore-ls can be quite hard to read and it is
not very intractable for postprocessing with sort|diff and the like.

The patch below provides a -f option which produces output with the
full key pathname on each line, and which disables the value
truncation and the `.'-padding when used with -p (since these latter
two aren't likely to be very useful when values are preceded by long
pathnames).

While I was at it I added the `-s' option to the usage message, where
it was previously missing.

The results looks like this:

...
/local/domain/1 = ""
/local/domain/1/vm = "/vm/8b5fd34a-e268-fab5-9cde-c06eda21df16"
/local/domain/1/device = ""
/local/domain/1/device/vbd = ""
/local/domain/1/device/vbd/2049 = ""
/local/domain/1/device/vbd/2049/virtual-device = "2049"
/local/domain/1/device/vbd/2049/device-type = "disk"
/local/domain/1/device/vbd/2049/protocol = "x86_32-abi"
...

Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com>
tools/xenstore/xsls.c